<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title></title>
	</head>
	<body>
		<script type="text/javascript">
			var p = {};
			p.name = "张三";
			p.age = 20;
			p.work = function() {

			}

			function Person(name, age) {
				this.name = name;
				this.age = age;
				this.work = function() {

				}
			}

			//静态属性
			Person.sex = '男';

			var p1 = new Person('张三', 20);
			var p2 = new Person('李四', 30);


			console.log(p1.sex);
			console.log(p2.sex);
			
			console.log(Person.sex);
			
		</script>
	</body>
</html>
